package com.sky.mapper;

import com.sky.annotation.AutoFill;
import com.sky.entity.DishFlavor;
import com.sky.enumeration.OperationType;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * TODO
 *
 * @Author mr.wu
 * @Data #{DATE} #{TIME}
 */
@Mapper
public interface DishFlavorMapper {

    @AutoFill(OperationType.INSERT)
    int insert(@Param("list") List<DishFlavor> list);

    void deleteFlavor(Integer id);

    void deleteByDishId(Long id);

    List<DishFlavor> getByDishId(Integer id);

    /**
     * PC端 根据菜品id查询口味
     * @param
     * @return
     */
    List<DishFlavor> getPcDishFlavors(Long id);
}
